package com.icart.entities;

import javax.persistence.*;

@Entity
@Table(name = "mk_salepic", schema = "amp", catalog = "")
public class MkSalepicEntity {
    private long picid;
    private long chnid;
    private String picurl;
    private Integer pickind;

    @Id
    @Column(name = "picid")
    public long getPicid() {
        return picid;
    }

    public void setPicid(long picid) {
        this.picid = picid;
    }

    @Basic
    @Column(name = "chnid")
    public long getChnid() {
        return chnid;
    }

    public void setChnid(long chnid) {
        this.chnid = chnid;
    }

    @Basic
    @Column(name = "picurl")
    public String getPicurl() {
        return picurl;
    }

    public void setPicurl(String picurl) {
        this.picurl = picurl;
    }

    @Basic
    @Column(name = "pickind")
    public Integer getPickind() {
        return pickind;
    }

    public void setPickind(Integer pickind) {
        this.pickind = pickind;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        MkSalepicEntity that = (MkSalepicEntity) o;

        if (picid != that.picid) return false;
        if (chnid != that.chnid) return false;
        if (picurl != null ? !picurl.equals(that.picurl) : that.picurl != null) return false;
        if (pickind != null ? !pickind.equals(that.pickind) : that.pickind != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = (int) (picid ^ (picid >>> 32));
        result = 31 * result + (int) (chnid ^ (chnid >>> 32));
        result = 31 * result + (picurl != null ? picurl.hashCode() : 0);
        result = 31 * result + (pickind != null ? pickind.hashCode() : 0);
        return result;
    }
}
